home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / c / jpl_c.zip / MODF.C < prev    next >
Text File  |  1986-05-18  |  640b  |  17 lines

  1. /* 1.0  04-27-84 */
  2. /************************************************************************
  3.  *            Robert C. Tausworthe                *
  4.  *            Jet Propulsion Laboratory            *
  5.  *            Pasadena, CA 91009        1984        *
  6.  ************************************************************************/
  7.     double
  8. modf(x, y)    /* return fractional part of x as double, set *y to
  9.            integer part of x, also double.            */
  10. /*----------------------------------------------------------------------*/
  11. double x, *y;
  12. {
  13.     double fint();
  14.  
  15.     return (x - (*y = fint(x)));
  16. }
  17.